﻿using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _48WPFMasterDetailBinding
{
    public class Category
    {
        public string Name { set; get; }
        public ObservableCollection<Product> Products { set; get; }

        public Category(string name, params Product[] products) 
        {
            this.Name = name;
            Products = new ObservableCollection<Product>();
            foreach (Product p in products) 
            {
                Products.Add(p);
            }
        }
    }
}
